所以我有一个表已经分解了月份和年份,例如,名为Month的字段中有7个(本月),而Year字段有2011年.还有额外的月份等等.我如何查询到只显示当前年份,月份?
如何在SQL中显示日期大于当前日期的内容?
我想提取数据,显示今天(现在)未来90天的所有内容.
我在想,=< {fn NOW()}但这似乎不适用于我的sql视图.
如何才能做到这一点?
我想能够在我的DTSX包中有一个SQL查询,我希望能够有一些提示来更新空列的值.看看我下面的内容:
UPDATE SF1411
SET [QuoteNumber] = '123456'
, [ItemNumber] = '123654-100'
, [DeleteItem] = 'NO'
WHERE [QuoteNumber] = '0'
Run Code Online (Sandbox Code Playgroud)
我希望能够提示您输入QuoteNumber和ItemNumber,然后根据需要更新脚本.这是可能的,如果可以,我该怎么办?
这里的新人如此忍受我.我有一个基本的XSL文件,它将读取我的xml数据.我试图将xml放入Excel.继承人我的问题.使用一个小的XML文件,它似乎很容易转换,但是这个XML文件有几个节点(我认为它们被称为),当我调用数据时,它不对.我想只显示XML检查部分的信息,然后以一种显示我想要的6或7列的方式在Excel中显示,然后显示数据.以下是我到目前为止的情况:
XML:
<bdiData>
<documentControlInfo>
<documentInfo>
<docDescription>Checks for Company X</docDescription>
<docID>
<ID>123456789</ID>
</docID>
<docModifier>My Company</docModifier>
<docCreateDate>2010-08-23</docCreateDate>
<docCreateTime>07:08:54-0700</docCreateTime>
<standardVersion>1.0</standardVersion>
<testIndicator>0</testIndicator>
<resendIndicator>0</resendIndicator>
</documentInfo>
<sourceInfo>
<sourceName>My Banking Name</sourceName>
<sourceID>
<idOther>ShortBankName</idOther>
</sourceID>
</sourceInfo>
<destinationInfo>
<destinationName>My Company</destinationName>
<destinationID>
<idOther>MYCO</idOther>
</destinationID>
</destinationInfo>
</documentControlInfo>
<checkItemCollection>
<collectionInfo>
<description>Items</description>
<ID>654811650</ID>
<Classification>
<classification>Items</classification>
</Classification>
</collectionInfo>
<checkItemBatch>
<checkItemBatchInfo>
<description>Paid Checks</description>
<ID>1239668334710</ID>
<Classification>
<classification>Paid Checks</classification>
</Classification>
</checkItemBatchInfo>
<checkItem>
<checkItemType>check</checkItemType>
<checkAmount>2960</checkAmount>
<postingInfo>
<date>2009-06-12</date>
<RT>87654321</RT>
<accountNumber>123465798</accountNumber>
<seqNum>007725552898</seqNum>
<trancode>001152</trancode>
<amount>2960</amount>
<serialNumber>55225410</serialNumber>
</postingInfo>
Run Code Online (Sandbox Code Playgroud)
XSL文件:
<xsl:stylesheet version="1.0"
xmlns="urn:schemas-microsoft-com:office:spreadsheet"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:user="urn:my-scripts"
xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:x="urn:schemas-microsoft-com:office:excel"
xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" >
<xsl:template match="/">
<Workbook …Run Code Online (Sandbox Code Playgroud) 在C#Web应用程序上工作,我的问题是只有一些值出现在报表上(这是我正在谈论的X轴,它只显示其他所有值).它只是展示了每一个.我怎样才能展示所有这些?
谢谢


我的代码:
<asp:Chart ID="Chart6" runat="server" DataSourceID="SqlDataSource13"
Palette="Chocolate" Width="800px">
<Series>
<asp:Series Name="Series1" CustomProperties="DrawingStyle=Cylinder"
IsValueShownAsLabel="True" LabelFormat="{C2}" Palette="Chocolate"
XValueMember="StartItem" YValueMembers="STDCOST2">
</asp:Series>
</Series>
<ChartAreas>
<asp:ChartArea Name="ChartArea1">
<AxisY IsLabelAutoFit="False" TextOrientation="Rotated90"
TitleFont="Verdana, 7pt">
<LabelStyle Font="Microsoft Sans Serif, 6.75pt" Format="{C2}" />
</AxisY>
<AxisX IsLabelAutoFit="False" LabelAutoFitMaxFontSize="8"
LabelAutoFitMinFontSize="7" LabelAutoFitStyle="None">
<LabelStyle Angle="90" Font="Microsoft Sans Serif, 6pt" Interval="Auto"
IsEndLabelVisible="False" />
<ScaleBreakStyle BreakLineStyle="None" />
</AxisX>
<AxisX2 IsLabelAutoFit="False" LabelAutoFitMaxFontSize="8"
LabelAutoFitStyle="None">
<LabelStyle Angle="45" />
</AxisX2>
<Area3DStyle Enable3D="True" />
</asp:ChartArea>
</ChartAreas>
</asp:Chart>
Run Code Online (Sandbox Code Playgroud) 我正在写一个与列表视图绑定的C#网页.我的客户希望能够输入可显示结果的某些内容或部分内容.例如,他想要一个文本框,他可以在其中输入电话号码,电话号码的一部分,姓名,城市或其他任何东西,然后会找到一种SP,然后列出信息.如何在SQL Sp或VS 2010中完成此操作?
做一个表达式我得到一个错误,有人可以在这里告诉我正确的语法吗?
=IIf(Fields!t_cpcp.Value ="310", "Purchased Material & Raw Material", Nothing)
=IIf(Fields!t_cpcp.Value ="320", "Manufacturing Direct Labor", Nothing)
=IIf(Fields!t_cpcp.Value ="325", "Subcontract Cost", Nothing)
=IIf(Fields!t_cpcp.Value ="330", "Engineering Direct Labor", Nothing)
=IIf(Fields!t_cpcp.Value ="340", "Manufacturing Labor O/H", Nothing)
=IIf(Fields!t_cpcp.Value ="345", "Engineering Labor O/H", Nothing)
=IIf(Fields!t_cpcp.Value ="350", "Material O/H", Nothing)
=IIf(Fields!t_cpcp.Value ="355", "Labor O/H Surcharge", Nothing)
=IIf(Fields!t_cpcp.Value ="360", "Subcontract Material Burden", Nothing)
=IIf(Fields!t_cpcp.Value ="MFD", "Manufactured Items", Nothing)
Run Code Online (Sandbox Code Playgroud) 如何在SQL中创建未来日期?例如,我希望能够使用我的日期范围并显示下个月的所有内容(采购订单),然后显示另外两个月,等等.我已经使用fn NOW()获取当前日期/时间但是这个根本没有帮助我显示下个月的记录等.
谢谢
这适用于在SQL Server 2008 R2中执行的SQL查询.
如何进行SQL查询并将参数设置为前N值.例如,第一个人想要看到前10个值,下一个可能是前50个,也许是前100个.我会说SELECT TOP = @ Value from Table吗?
谢谢
是的,这是针对SQL Server的.标准查询,显示所有内容,但ID类似于根据用户的输入限制返回的行数.
sql ×8
sql-server ×4
t-sql ×3
c# ×2
excel ×1
if-statement ×1
ssis ×1
ssrs-2008 ×1
view ×1
xslt ×1