Showing posts with label refer. Show all posts
Showing posts with label refer. Show all posts

Sunday, March 11, 2012

Accentuated characters SQL

I use Webmatrix together with Frontpage 2002.
In one of my Webmatrix pages I refer to a field "Prénom" when doing queries.

Sometimes after publishing these pages from my local to my hosted server the é disappears in the source code and SQL server does not find the column.

I have the feeling it has to do with codepage and/or Content.

Has anyone a precise idea.for a start, your columns should be of type nvarchar (or simlar n-prefixed column)
and literal strings in SQL should be n-prefixed also

UPDATE tblWhatever SET columnName = N'somé string with accénts'

this might help, if the problem is what I think it is.|||This is the case.

I have now realized that Frontpage produces pages with US/European character set, whereas Webmatrix uses UTF-8. Seems to be quite a mess making things compatible ...
Worse, when opening a Frontpage Ansi produced page with Web Matrix, this program strips out the accentuated characters, and you lose them in the process of saving.

Reverse, when you change the default in Frontpage to UTF-8, the european characters become unreadable in Web Matrix !

I do not yet know how to fix this.|||Frontpage?? Jesus H. Smith! I didn't think anyone still used that ;-)

1. what version? 2. is there anything in the options dialog which can force UTF-8 in FP?

Saturday, February 11, 2012

about Efficiency

I want to select one field from a table,but it should on some conditions
which refer to 5 table ,such as A.FILED1=B.FIELD1 AND B.FIELD2=C.FIELD3 AND
...
Should I use case "select sum(a.amount) from a,b,c,... where
a.field1=b.field1 and b.field2=c.field2 and ..." or "select sum(a.amount)
from select b.field1 from select c.field2 from..."?And which case is more
efficiency?
thanks!

?е??ε?????? в??????select ..from ...where ..and ..and..and ..and ..select ..from
select ..from select ..from .....?Ч??
ллOn 20.09.2006 10:51, yicong wrote:

Quote:

Originally Posted by

I want to select one field from a table,but it should on some conditions
which refer to 5 table ,such as A.FILED1=B.FIELD1 AND B.FIELD2=C.FIELD3 AND
...
Should I use case "select sum(a.amount) from a,b,c,... where
a.field1=b.field1 and b.field2=c.field2 and ..." or "select sum(a.amount)
from select b.field1 from select c.field2 from..."?And which case is more
efficiency?


I cannot make much sense of this. Please rephrase your question and
especially provide more detail (DDL, DML).

A general remark: if you have two equivalent DML statements you can
easily check with MS tools (Profiler, Query Analyzer) which of the two
is more efficient.

Regards

robert|||yicong wrote:

Quote:

Originally Posted by

I want to select one field from a table,but it should on some conditions
which refer to 5 table ,such as A.FILED1=B.FIELD1 AND B.FIELD2=C.FIELD3 AND
...
Should I use case "select sum(a.amount) from a,b,c,... where
a.field1=b.field1 and b.field2=c.field2 and ..." or "select sum(a.amount)
from select b.field1 from select c.field2 from..."?And which case is more
efficiency?


select sum(a.amount)
from a
join b on a.field1 = b.field1
join c on b.field2 = c.field2
...