Categories
Mastering Development

Map

cityContactMap.computeIfAbsent(cityName,cityName -> new ArrayList<>()) .add(new AddressBook( last_Name, first_Name, address, cityName, stateName, phone_Number, zip_Code, email )); public void displayCity() { System.out.println("Enter City name \n"); String cityNameFilter = sc.next(); List<Object> objectList = new ArrayList<>(); objectList = stateContactMap.entrySet().stream() .filter(e -> e.getKey().equals(cityNameFilter)) .collect(Collectors.toList()); int num = objectList.size(); System.out.println("List of city objects :"+objectList); } MY output is like this List […]

Categories
Apple User Help

What Data was uploaded when app accessing our Contacts? [closed]

From the moment we switch from Skype/AIM to Apps like Viber and WhatsApp, we’ve become comfortable with IM Apps accessing our contacts. Honestly, I am never fully comfortable with that idea. However, I am much more interested in learning what Data in Contacts did they upload to their server? Will Apple restricts access only to […]

Categories
CMS Drupal Mastering Development

Form with multiple Submit and Validation handlers not working if the buttons are ajax enabled

I have multiple submit buttons with separate submit and validate handlers and all the buttons in the form are ajax enabled. But the submit and validate functionality of the form breaks. As I can see the validate and submit function written last in the code are being called on each submit instead of the respective […]

Categories
Database Development

Database normal forms

if a prime attribute in specific one of the attributes of the primary key depend on another attribute of the primary key which normal from this violates? for example lets say we have a relation whose attributes are as follows (Inv #, Cust #, Name, Address, ShipMethod, Date, Quant, Prod #, Descr, Price, Amount). with […]

Categories
Database Development

How do others know what is delivery address and invoice address if they are in the same table?

When I searched around, the recommended way is to use the invoice address and delivery address in the same table and use a field "type" to show what it is. For example Addresses(Company, address, city, type) Type = 1: The address is a delivery address Type = 2: The address is a invoice address Type […]

Categories
Database Development

How do others know what is delivery address and invoice address if they are in the same table?

When I searched around, the recommended way is to use the invoice address and delivery address in the same table and use a field "type" to show what it is. For example Addresses(Company, address, city, type) Type = 1: The address is a delivery address Type = 2: The address is a invoice address Type […]

Categories
Arduino Ask Engineering

Programming AT24C16 EEPROM with arduino nano

I have been trying to program an AT24C16 EEPROM and have set up a circuit as per the attached image. I have been using the following arduino code: #include <Wire.h> #define disk1 0x50 //Address of 24LC256 eeprom chip void setup(void) { Serial.begin(9600); Wire.begin(); unsigned int address = 10; writeEEPROM(disk1, address, 72); Serial.println(readEEPROM(disk1, address), DEC); } […]

Categories
Arduino Ask Engineering

Programming AT24C16 EEPROM with arduino nano

I have been trying to program an AT24C16 EEPROM and have set up a circuit as per the attached image. I have been using the following arduino code: #include <Wire.h> #define disk1 0x50 //Address of 24LC256 eeprom chip void setup(void) { Serial.begin(9600); Wire.begin(); unsigned int address = 10; writeEEPROM(disk1, address, 72); Serial.println(readEEPROM(disk1, address), DEC); } […]

Categories
Arduino Ask Engineering

Programming AT24C16 EEPROM with arduino nano

I have been trying to program an AT24C16 EEPROM and have set up a circuit as per the attached image. I have been using the following arduino code: #include <Wire.h> #define disk1 0x50 //Address of eeprom chip void setup(void) { Serial.begin(9600); Wire.begin(); unsigned int address = 1; writeEEPROM(disk1, address, 72); Serial.print(readEEPROM(disk1, address), DEC); } void […]

Categories
Mastering Development

SQL Group by using different conditions and multiple columns

I have an Addresses Table, with columns being: A,B,C,D……Address, Number, State, City, Zip** I need to get a count of distinct addresses that can be grouped by 2 different conditions: (Address, Number, State, City) OR (Address, Number, Zip) The reason for the 2 conditions is that Zip can be null in some cases with City […]