Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
goodbyemre
Starting Member
3 Posts |
Posted - 2008-12-06 : 09:07:05
|
i have been issued with a task and an excel spreadsheet where by obviously cells of data are being used to add multiply with each other and numbers ETC which come up with a price list of products. However i have to make this into a MYSQL database.simply putting the data into the database wouldn't be a problem however i that would not have the maths functions that the Excel spreadsheet has. i've tried a few ways to get the SQL database to do this however one maths function puts the results into a temporary table by the look of it, rather then back into my data table as i was wanting, this means when it comes to the next cell, there is no data to do the maths function onthis for exmaple is what i was wanting:ROW1 + ROW2 = Row3ROW3 * 5 = ROW4what happens is:Row1 + ROW2 = <datainserts in temporary table>Row3<which is empty> * 5 = <SQL Error message>basically i'm trying to get an SQL table to run like an Excel spreadsheet.answers would be appreciated. cheers |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2008-12-06 : 09:34:11
|
http://weblogs.sqlteam.com/brettk/archive/2005/05/25/5276.aspx |
|
|
goodbyemre
Starting Member
3 Posts |
Posted - 2008-12-06 : 10:13:40
|
hasn't really answered the question |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2008-12-06 : 12:32:26
|
Well, you haven't really stated it either. Please read the post again and repost your question according to its guidelines.Not to mention SQL Team is a SQL Server website, we don't specialize in MySQL.However, if you're trying to replicate Excel functions and calculations in any SQL product, you're going to be frustrated. You haven't shown any particular reason why it needs to go into a SQL database, and doing so won't serve your needs with regards to the formulas. |
|
|
goodbyemre
Starting Member
3 Posts |
Posted - 2008-12-07 : 05:47:37
|
this is going to be a long post.basically the way these people do things with regards to their website is they generate a spreadsheet of prices like so: Row A RowB ROWC RowD RowE RowF RowG RowH RowI ROWJGlassPrice DoorPrice NetPrice fixing creditcharge listprice listprice50%deduction VAT listprice+VAT 10%online discount105.00 116.42 =B2*0.55 100.00 85.00 =(A2+C2+D2+E2)*4 =F2/2 =G2*0.175 =G2*1.175 =H2*0.9the results of the formula then MANUALLY get put in to the website by hand.what i've been told to do is create this spreadsheet with said formulas into an SQL database (the MySQL will just be the method of putting it on the website) however whenever i've been doing it i can get the results of ROW C however the resulting data goes into a temporary table rather than into the actual pricing table i've created meaning when it gets to the formula in ROWF there is nothing in the C Rows to get the formula working so it doesn't. this ultimately breaks down the table meaning the rest of the formula will not work. i was just wondering how i could go about getting this SQL table to function like they want it to |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-12-07 : 07:48:16
|
how are you trying to transfer row data to table? using openrowset? |
|
|
|
|
|