sql server currency query

They have: 26 posts

Joined: Nov 2001

I have converted a data type of a table (sql server database) to be smallmoney, but on entering any data, either directly into the database or via an input form, the £ sign is not displayed in the database and hence not on the web page.

eg. if i enter £20.50 it displays as 20.5

How can i change this to show as £20.50?

Thanks,
Mark

He has: 1,016 posts

Joined: May 2002

<?php
$money1
= 20.5;
$money2 = \"£\" . number_format($money1, 2);
//Result:
$money2 = £20.50
?>

They have: 26 posts

Joined: Nov 2001

Thanks, im using ASP, so i guess its a slightly different syntax,

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.