cancel
Showing results for 
Search instead for 
Did you mean: 

How control same inventary in two companies with stock???

Former Member
0 Kudos

Hello, I need to control the same inventary for two differents companies.

The both companies have the same items or if in one i create a new item in the other must create the same.

The problem is with the stock.

What can i do to control de entries and exits to if i sold or buy an item in one company, in the other, the stock increment and de middle price change correctly???

King Regards,

Alfredo Temprano.

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member185703
Active Contributor
0 Kudos

Hi Alfredo,

Not sure what you really want to do?

If the two companies just have to handle the inventory transactions 100% the same (I suppose the second company is just some kind of fallback company in case of a hardware or network failure?), you could just:

- hook on SBO_SP_TransactionNotification + whenever a relevant transaction occurs...

OR

- use the DIEventsService tool instead of touching SBO_SP_... yourself;

Then extract the data (e.g. through DI API's XML capabilities) + import the XML into the second company through DI API...

The average price should be the same then, if there are no users selling and buying?!

Does this make sense?

Please clarify the case a bit more if you think I didn't "hit the mark"!

Regards,

Frank

Former Member
0 Kudos

Thanks for response.

In mi case the second company is not for a failure of the hardware or network, is becouse in one company have a customers and a specific financials... and in the second have diferents properties but the same inventary.

I want to have the same inventary, consolidate the both companies.

I like you explain of extract the data in a XML and then import in the other company but i dont have idea of how must i do.

I don find esplain of the SBO_SP_TransactionNotification.

Can you explain me or tell me where can i found documentation???

Thank for all.

Regards,

Alfredo Temprano.

Former Member
0 Kudos

Hi Alfredo,

Just make a search and you will find lot of post about it:

A good place to start:

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/34f5cd90-0201-0010-939b-abb...

How to use the SP from windows services

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/53cefa6a-0a01-0010-cd8e-e7c...

Some comments about it:

Hope helps

Ibai Peñ

Former Member
0 Kudos

Thanks,

Can I create a stored procedure for all moviments of inventary? I need to control the sales, purchases, stock transfers, stock revaluations... all that afects to the prices, stock...

I need copy all inventary transactions that make in one company to the second company.

Former Member
0 Kudos

It is suppsed that you are not allowed to create new Stored Procedures. You can only use the SBO_SP_TransactionNotification. You should do every statement there.

As I said, this is the theory.

Regards,

Ibai Peñ

former_member185703
Active Contributor
0 Kudos

Hi Alfredo,

There's no need to create further SPs.

All objects (= transactions = business objects) call the SBO_SP_... as the last action just before the the data are written to the DB!

It's just a matter of the object's ID (most can be found in the DI API documentation) + the key of the particular record which is going to be modified to find the data which you then want to send to the 2nd DB.

Potential Exception:

Stock revaluation: Not sure which objects are touched; this could be a gap.

You need to carefully analyze what you need + what you can get from SBO_SP_... + what is possible through DI API!!!

I strongly suggest that you involve a B1 partner close to you who is experienced in that area!

Please note that when you start to work with DI API (what is what you need to do in the end to really transfer the data from one DB to the other) you should make yourself familiar with it through the SDK(!) E-learning (available on the SAP Business One developer area here on SDN) + the documentation in the SDK Helpcenter (same story)!

Regards,

Frank

Former Member
0 Kudos

Sorry, maybe i didnt explain clearly.

I dont want create new stored procedures. I want said that if i can use SP_TransactionNotification to control all the moviments on the inventary, stock, prices... to pass this transactions to the other company.

King regards,

Alfredo Temprano.

Former Member
0 Kudos

Any object from the DI API could be handled on the stored procedure. Have a look at the BoObjectTypes enumeration in the DI API.

As Frank said, a very important issue in this case is DI API.

Not all data is avaiable from the DI API. For example, you have a new customer with its bank data in database 1. Using DI API you can´t create the bank, so you will not be able to replicate 100%.

This is just an example (I know in 2005 this functionality is avaiable), but there are some other areas which are not exposed.

We have already faced this problem, and we haven´t found a 100% solution.

Regards,

Ibai Peñ