049 tracking thread

A place for developers to discuss development of OSA
Message
Author
Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#71 Post by Vaughn » Sun Apr 22, 2018 3:14 am

The error does not look related to the 'Import' values. You can just try to execute the object_add by itself and verify. I am still at work and will look at it in a couple hours when I get home. I think the @Results is meant to return the new Object_ID, which would need to be assigned to something, and is not valid in that CALL. The object_property stuff does not return anything and does not need a @result.

I did not put that 'Import' stuff in there and the user should be the 'SYSTEM' parameter. Without out my code/db here I can't verify the actual parameters though, so I will update this in a bit. I just want to say to test the different type of CALL statements by themselves...


Vaughn

User avatar
kherron
Posts: 645
Joined: Mon Dec 05, 2011 10:44 am
Location: Jacksonville, Fl.
Contact:

Re: 049 tracking thread

#72 Post by kherron » Mon Apr 23, 2018 10:35 am

OK,

It appears that the Alias property is missing in the Export Text?

The Add_Object wants 9 values sent to it, and if you look at the 1st line above, we are only sending 8. And the the last one is an OUT.

User avatar
kherron
Posts: 645
Joined: Mon Dec 05, 2011 10:44 am
Location: Jacksonville, Fl.
Contact:

Re: 049 tracking thread

#73 Post by kherron » Tue Apr 24, 2018 11:43 am

So,

I have repaired the function in my DB to correct the export text as follows:

Code: Select all

CALL osae_sp_object_add ('Test User','','Test User','PERSON','','CCSG',30,1,@results);
Which now has 9 parameters, however, I'm now getting this error:

Code: Select all

Source: System.Web
Message: Exception of type 'System.Web.HttpUnhandledException' was thrown.
Inner Exception: MySql.Data.MySqlClient.MySqlException (0x80004005): OUT or INOUT argument 9 for routine osae.osae_sp_object_add is not a variable or NEW pseudo-variable in BEFORE trigger

Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#74 Post by Vaughn » Wed Apr 25, 2018 11:25 am

I added the alias here and ran an export/import from the database tools and I don't get that error. Can you test it from workbench or something and see if you get the same error?

Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#75 Post by Vaughn » Sun Apr 29, 2018 4:58 am

If you want to commit the import code, I will test it.

User avatar
kherron
Posts: 645
Joined: Mon Dec 05, 2011 10:44 am
Location: Jacksonville, Fl.
Contact:

Re: 049 tracking thread

#76 Post by kherron » Mon Apr 30, 2018 5:34 am

Sorry for the delay, but yes, It does work just fine in workbench..... :?:

Here is a small snippet of my code...

Code: Select all

string objSQL = "CALL osae_sp_object_add('Hank','Henry','Web UI user','PERSON','','',30,1,@results);";
OSAESql.RunSQL(objSQL);
But, I'm still getting this error:

Code: Select all

Source: System.Web
Message: Exception of type 'System.Web.HttpUnhandledException' was thrown.
Inner Exception: MySql.Data.MySqlClient.MySqlException (0x80004005): Fatal error encountered during command execution. ---> MySql.Data.MySqlClient.MySqlException (0x80004005): Parameter '@results' must be defined.

Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#77 Post by Vaughn » Fri May 04, 2018 9:21 am

I am thinking about just removing the output parameter from the DB call. I can add a select in the API to leave the functionality alone at that level so we don't have to modify any of the programs that use that API. Then all the DB calls will stay nice and simple.

You OK with that? If so, I can send you the SQL for the proc and commit the API changes.

Vaughn

Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#78 Post by Vaughn » Sat May 05, 2018 8:35 am

After actually going in to change the proc, the @result is not used for a new record id, it looks like maybe what is used to display error codes on the web site, so I did not remove them.

I will go back to trying to get my separate little project running to experiment with using multiple statements in the call to define the parameter like: Result='';CALL osae_sp_object_add..."

Hoping something like that will clear the undefined error

Vaughn

User avatar
kherron
Posts: 645
Joined: Mon Dec 05, 2011 10:44 am
Location: Jacksonville, Fl.
Contact:

Re: 049 tracking thread

#79 Post by kherron » Sun May 06, 2018 8:05 am

Nor sure about this,

But I did find this information while doing some research on the issue.
Look at this page: http://blog.tjitjing.com/index.php/2009 ... fined.html

It maybe could be a simple fix.....

Vaughn
Site Admin
Posts: 1432
Joined: Thu May 13, 2010 2:17 pm

Re: 049 tracking thread

#80 Post by Vaughn » Mon May 07, 2018 2:31 am

I did upgrade the .NET Connector this version...

I will try the connection string modifier and read over that article more when I get home.


Vaughn

Post Reply