Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Does this make sense?
Message
De
31/01/2013 16:55:25
 
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Desktop
Divers
Thread ID:
01564885
Message ID:
01564895
Vues:
28
>>>>Hello all
>>>>
>>>>I've got two tables (TestResult and IndvStats) and a generic userid.
>>>>
>>>>Userid has Insert, Update and Select rights on both tables.
>>>>
>>>>The only difference between the two tables is that TestResult has two fields that are defaulted to 0 on new record insertion.
>>>>
>>>>Userid can insert into IndvStats, but not into TestResult. Would these two field constraints cause this? I'm going to remove the constraints and see if that is indeed the issue, but if so - Why? And if it doesn't make a difference, has anyone seen behavior like this in SQL?
>>>>
>>>>Thanks
>>>>
>>>>Dorris
>>>
>>>Are you omitting these fields in your insert statement? I don't think that the problem is related with constraints.
>>
>>Yes, I am not including these in the initial creation of the record at the beginning of the test. They are updated at the end of the test.
>
>Can you show some code just to see what we're talking about?

Right now, I'm testing from the VFP command window so the code looks like (after variables are assigned a value)
msql1 = "Execute InsertTestResults "
m.param1 = "?m.sbank, ?m.scn, ?m.tcn"
ms1 = sqlexec(mconn, msql1 + m.param1)
mconn = SQLStringConnect(SQLCStr) where
SQLCSTR = "Driver = SQL Server;Server = DEVSERVER;uid = 'Herbie';Trusted_Connection = Yes;APP=Microsoft Visual FoxPro; WSID = PC1; Database = DLI_Testing"

yes, the connection is good.

InsertTestResults is basically, after parameters are defined

Insert into TestResult (Subbank, SCN, TCN) values ('E0' + @Subbank, @SCN, @TCN)
"You don't manage people. You manage things - people you lead" Adm. Grace Hopper
Pflugerville, between a Rock and a Weird Place
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform