PlanetTech
Posts: 13
|
Posted: 09/16/2009, 10:06 PM |
|
Have a custom insert to a stored procedure. I believe its correct but no data is being inserted
so can't be.
How can I view what is being executed and what event do I need to use to display this prior to
to the insert being execute?
Thanks
|
|
|
Edd
Posts: 547
|
Posted: 09/17/2009, 7:12 PM |
|
Custom inserts work with Stored procedures very well.
Things to check:
1. That CCS to Stored Proc parameters match (especially passing stings) and all fields don't pass NULL's unless the stored procedure expects it.
2. Do a manual test on the Stored Proc to see if it functions as expected.
3. Check the Stored Proc's permissions to see if you can call it.
4. That you have "RaiseError" in your stored proc for error traps and that you return 0 or -1 if success or failure.
I used stored procs all the time and they always work when the above is followed.
Hope that helps - Edd
_________________
Accepting and instigating change are life's challenges.
http://www.syntech.com.au |
|
|
PlanetTech
Posts: 13
|
Posted: 09/17/2009, 7:42 PM |
|
Thanks Edd.
Just sorted earlier. Had two problems.
(1) Non of my controls were bound to a data source. My initial thought was that as I was just adding data via SP, the controls did not need be bound to a source to retrieve data.
(2) On retrieving the SP attributes on the Custom Insert dialog, it had set the size of one of my parameters to 0 (zero). The actual SP value was nvarchar(MAX). After changing to 4000 all worked fine.
|
|
|
|